interface HospitalBase {
  id: string;
  createTime: string;
  updateTime: string;
  isDeleted: number;
  param: Param;
  hoscode: string;
  hosname: string;
  hostype: string;
  provinceCode: string;
  cityCode: string;
  districtCode: string;
  address: string;
  logoData: string;
  intro: string;
  route: string;
  status: number;
}

export interface HospitalListItem extends HospitalBase {
  bookingRule: BookingRule;
}

export type HospitalListItems = HospitalListItem[];

interface BookingRule {
  cycle: number;
  releaseTime: string;
  stopTime: string;
  quitDay: number;
  quitTime: string;
  rule: string[];
}

interface Param {
  hostypeString: string;
  fullAddress: string;
}

// 定义单条省份信息结构
interface ProvinceItem {
  id: number;
  createTime: string;
  updateTime: string;
  isDeleted: number;
  param: object;
  parentId: number;
  name: string;
  value: string;
  dictCode?: any;
  hasChildren: boolean;
}

//定义 ProvinceItem 的复数类型
export type ProvinceItems = ProvinceItem[];
export type ProvinceResponse = ProvinceItems;

//定义请求获取医院列表的结构
export interface GetHospitalListParams {
  page: number;
  limit: number;
  hoscode?: string;
  hosname?: string;
  hostype?: string;
  provinceCode?: string;
  cityCode?: string;
  districtCode?: string;
  status?: number;
}

//医院列表响应结果的结构
export interface GetHospitalListResponse {
  content: HospitalListItem[];
  pageable: Pageable;
  last: boolean;
  totalPages: number;
  totalElements: number;
  first: boolean;
  sort: Sort;
  numberOfElements: number;
  size: number;
  number: number;
  empty: boolean;
}

interface Pageable {
  sort: Sort;
  pageNumber: number;
  pageSize: number;
  offset: number;
  paged: boolean;
  unpaged: boolean;
}

interface Sort {
  sorted: boolean;
  unsorted: boolean;
  empty: boolean;
}

//获取医院详细信息的结构
export interface GetHospitalShowResponse {
  bookingRule: BookingRule;
  hospital: HospitalShow;
}

//医院详情的医院基本信息
interface HospitalShow extends HospitalBase {
  bookingRule: null;
}

//单条排班医生的结构
export interface DoctorItem {
  id: string;
  createTime: string;
  updateTime: string;
  isDeleted: number;
  param: Params;
  hoscode: string;
  depcode: string;
  title: string;
  docname: string;
  skill: string;
  workDate: string;
  workTime: number;
  reservedNumber: number;
  availableNumber: number;
  amount: number;
  status: number;
  hosScheduleId: string;
}



interface Params {
  dayOfWeek: string;
  depname: string;
  hosname: string;
}

//定义单个科室的结构
export interface DepartmentItem {
  depcode: string;
  depname: string;
  children: DepartmentItem[] | null;
}

//请求科室响应结果的结构
export type GetDepartmentResponse = DepartmentItem[];
export type DepartmentItems = DepartmentItem[];

//定义获取排班规则的参数结构
export interface GetScheduleParams{
  page: number;
  limit: number;
  hoscode: string;
  depcode: string;
}

export interface GetScheduleResponse {
  total: number;
  bookingScheduleList: BookingScheduleList[];
  baseMap: BaseMap;
}

interface BaseMap {
  hosname: string;
}

export interface BookingScheduleList {
  workDate: string;
  workDateMd?: any;
  dayOfWeek: string;
  docCount: number;
  reservedNumber: number;
  availableNumber: number;
  status?: any;
}
//获取排班医生的参数结构
export interface GetDoctorsParams{
  hoscode: string;
  depcode: string;
  workDate: string;
}

//获取某天排班医生的响应
export type DoctorsResponse = DoctorItem[];

